<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">
<body>
	<div th:fragment="commonContent">
	  <div class="modal fade" id="userOneselfModal" tabindex="-1" role="basic" aria-hidden="true">
		<div class="modal-dialog">
			<div class="modal-content">
				<div class="modal-header">
					<button type="button" class="close" data-dismiss="modal" aria-hidden="true"></button>
					<h4 class="modal-title">个人资料维护</h4>
				</div>
				<div class="modal-body">
					<form id="userOneselfForm" role="form" class="form-horizontal">
		            	<!-- <div class="form-group ">
							<label class="control-label col-md-3">头像:</label>
							<div class="col-md-9">
								<div class="fileinput fileinput-new" data-provides="fileinput">
									<div class="fileinput-preview thumbnail" data-trigger="fileinput" style="width: 200px; height: 150px;">
										<img th:if="${session.USER_LOGIN.userPhoto}" th:src="@{'/common/showImage?filePath='+${session.USER_LOGIN.userPhoto}}"/>
									</div>
									<div>
										<span class="btn default btn-file">
											<span class="fileinput-new">选择图片</span>
											<span class="fileinput-exists">编辑</span>
											<input type="file" name="userPhoto">
										</span>
										<a href="javascript:;" class="btn red fileinput-exists" data-dismiss="fileinput">删除</a>
									</div>
								</div>
							</div>
						</div> -->
					    <div class="form-group">
					        <label class="col-md-3 control-label">姓名:</label>
					        <div class="col-md-5">
					        	<input type="text" name="name" class="form-control" th:value="${session.USER_LOGIN.name}" required="required" maxlength="50"/>
					        </div>
					    </div>
					    <div class="form-group">
					        <label class="col-md-3 control-label">出生日期:</label>
					        <div class="col-md-5">
					        	<input type="text" id="birthday" name="birthday" class="form-control datepicker"
					        	th:value="${#dates.format(session.USER_LOGIN.birthday, 'yyyy-MM-dd')}" required="required" maxlength="10" readonly="readonly"/>
					        </div>
					    </div>
					    <div class="form-group">
					        <label class="col-md-3 control-label">电话:</label>
					        <div class="col-md-5">
					        	<input type="text" name="phone" class="form-control" th:value="${session.USER_LOGIN.phone}" required="required" maxlength="11"/>
					        </div>
					    </div>
					  	<div class="form-group">
					        <label class="col-md-3 control-label">邮箱:</label>
					        <div class="col-md-5">
					        	<input type="text" name="email" class="form-control" th:value="${session.USER_LOGIN.email}" required="required" maxlength="50"/>
					        </div>
					    </div>
					    <input type="hidden" name="id" th:value="${session.USER_LOGIN.id}">
		            </form>
				</div>
				<div class="modal-footer">
					<button type="button" class="btn btn-primary" onclick="saveUserOneself()">保存</button>
					<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
				</div>
			</div>
		</div>
	</div>
	<div class="modal fade" id="userPasswordModal" tabindex="-1" role="basic" aria-hidden="true">
		<div class="modal-dialog">
			<div class="modal-content">
				<div class="modal-header">
					<button type="button" class="close" data-dismiss="modal" aria-hidden="true"></button>
					<h4 class="modal-title">密码修改</h4>
				</div>
				<div class="modal-body">
					<form id="userPasswordForm" role="form" class="form-horizontal">
					    <div class="form-group">
					        <label class="col-md-3 control-label">原密码:</label>
					        <div class="col-md-5">
					        	<input type="password" name="password" class="form-control" required="required" maxlength="50"/>
					        </div>
					    </div>
					    <div class="form-group">
					        <label class="col-md-3 control-label">新密码:</label>
					        <div class="col-md-5">
					        	<input type="password" id="newPassword1" name="newPassword" class="form-control" required="required" maxlength="50"/>
					        </div>
					    </div>
					    <div class="form-group">
					        <label class="col-md-3 control-label">确认新密码:</label>
					        <div class="col-md-5">
					        	<input type="password" id="newPassword2" class="form-control" required="required" maxlength="50"/>
					        </div>
					    </div>
					    <input type="hidden" name="id" th:value="${session.USER_LOGIN.id}">
		            </form>
				</div>
				<div class="modal-footer">
					<button type="button" class="btn btn-primary" onclick="saveUserPassword()">保存</button>
					<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
				</div>
			</div>
		</div>
	</div>
  </div>
</body>
</html>